package com.controller;


import com.model.auto.vo.StuArchivesRelSaveVo;
import com.service.IStuArchivesRelService;
import com.util.R;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * <p>
 * 档案信息配置信息 前端控制器
 * </p>
 *
 * @author astupidcoder
 * @since 2022-09-14
 */
@RestController
@RequestMapping("/stuArchivesRel")
public class StuArchivesRelController{
    @Autowired
    private IStuArchivesRelService stuArchivesRelService;

    @PostMapping("/getNotAdmitted")
    public R getNotAdmitted(Integer stuid) {
        System.out.println("============stuid"+stuid+"===============");
        return R.ok(stuArchivesRelService.getNotAdmitted(stuid));
    }

    @PostMapping("/saveOrUpdateAdmitted")
    public R saveOrUpdate(@RequestBody List<StuArchivesRelSaveVo> stuArchivesRelSaveVo) {
        boolean bool=stuArchivesRelService.saveOrUpdateRel(stuArchivesRelSaveVo);
        return R.ok();
    }
}
